using AndyPike.Commons.TestSupport;
using NUnit.Framework;
using NUnit.Framework.SyntaxHelpers;
using WatiN.Core;

namespace AndyPike.Snowflake.Web.Tests.Acceptance
{
    public class When_the_homepage_is_requested : AcceptanceTestBase
    {
        [Test, Category("Acceptance")]
        public void Should_render_the_homepage()
        {
            using(var browser = new IE(BuildUrl("Home", "Index")))
            {
                Assert.That(browser.Title, Is.EqualTo(string.Format("{0} - Home", productName)));
                Assert.That(browser.ContainsText(string.Format("Welcome to {0}", productName)), Is.True);
            }
        }
    }
}